﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace TfsBugger.Util
{
    public static class GenericListExtensions
    {
        public static void AddIfNotPresent<T>(this List<T> list, T item)
        {
            if (!list.Contains(item))
                list.Add(item);
        }


        public static void RemoveIfPresent<T>(this List<T> list, T item)
        {
            if (list.Contains(item))
                list.Remove(item);
        }
    }
}
